@include("user.head")
<link rel="stylesheet" href="<%url('user/css/zixun.css')%>">

<div id="zx_content">
    <div class="main_news">
    	<div class="main_left">
    		<div class="daodu information_hot" id="hotNews"></div>
    		<div class="yaowen">
    			<ul id="yaowen">
    			</ul>
    		</div>
    	</div>

    	<div class="main_right">
    		<div class="container-fluid tan_name">
			    <div class="navbar-header">
			      	<span class="navbar-brand">碳交易指数</span>
			    </div>
			</div>
			<div class="line_img">
				<img src="<%url('user/img/line.jpg')%>" alt="">
			</div>
    	</div>
    </div>

    <div class="zx_banner">
    	<img src="<%url('user/img/0001.jpg')%>" alt="">
    </div>

    <div class="cate_news">
    	<div class="news_left">
    		<div class="news_expand">
    			<div class="news_warp">
    				<div class="news_name">
    					资讯新闻
    				</div>
    				<ul class="news_links" id="in_news">
    				</ul>
    			</div>

    			<div class="news_warp">
    				<div class="news_name">
    					开发区
    				</div>
    				<ul class="news_links"  id="in_dzone">
    				</ul>
    			</div>

    			<div class="news_warp">
    				<div class="news_name">
    					机构与业绩
    				</div>
    				<ul class="news_links"  id="in_results">
    				</ul>
    			</div>

    			<div class="news_warp">
    				<div class="news_name">
    					碳排放资讯
    				</div>
    				<ul class="news_links" id="in_emissions">
    				</ul>
    			</div>
    		</div>
    	</div>
    	<div class="news_right">
            <div class="col-xs-12 no_padding_both">
                <div class="col-xs-12 foot-xbj no_padding_both">
                    <a href="#" class="thumbnail">
                      <img data-src="holder.js/100%x180" alt="100%x180" src="" data-holder-rendered="true" style="height: 180px; width: 100%; display: block;">
                    </a>
                </div>
                <div class="col-xs-12 foot-xbj no_padding_both">
                    <a href="#" class="thumbnail">
                      <img data-src="holder.js/100%x180" alt="100%x180" src="" data-holder-rendered="true" style="height: 180px; width: 100%; display: block;">
                    </a>
                </div>
            </div>
    	</div>
    </div>
</div>
@include("user.footer")
@include("user.common")
<script>
    $(".life_nav").mouseover(function() {
        $(this).css("background-color","#e7e7e7");
    })
    $(".life_nav").mouseout(function() {
        $(this).css("background-color","#F8F8F8");
    })
</script>
<script type="text/html" id="in_newsTemp">
{%each list as value index}
    <li><a href="information/detail?nid={%value.id}">{%truncateText(value.title, 20)}</a></li>
{%/each}
</script>
<script type="text/html" id="yaowenTemp">
{%each list as value index}
    <li><a href="information/detail?nid={%value.id}">{%truncateText(value.title, 12)}</a></li>
{%/each}
</script>

<script type="text/html" id="hotNewsTemp">
{%each list as value index}
    {%if index % 5 == 0}
        <div class="meg_box">
            <div class="row">
            <h3>
                <div class="col-xs-12"><a href="information/detail?nid={%value.id}">{%truncateText(list[index].title, 22)}</a></div>
            </h3>
            <p>
                <div class="col-xs-6"><a href="information/detail?nid={%value.id}">{%truncateText(list[index + 1].title, 16)}</a></div>
                 <div class="col-xs-6"><a href="information/detail?nid={%value.id}">{%truncateText(list[index + 2].title, 16)}</a></div>
            </p>
            <p>
                <div class="col-xs-6"><a href="information/detail?nid={%value.id}">{%truncateText(list[index + 3].title, 16)}</a></div>
                 <div class="col-xs-6"><a href="information/detail?nid={%value.id}">{%truncateText(list[index + 4].title, 16)}</a></div>
            </p>
            </div>
        </div>
    {%/if}
{%/each}
</script>


<script type="text/javascript">
    $.get("api/news_list",{
        current : 0,
        rowCount : 20,
        hot : 1,
    },function(data) {
        var html = template("hotNewsTemp", {list: data.data});
        $("#hotNews").html(html);
    });
    $.get("api/news_list",{
        current : 0,
        rowCount : 3,
        type : 4,
    },function(data) {
        var html = template("yaowenTemp", {list: data.data});
        $("#yaowen").html(html);
    });
    $.get("api/news_list",{
        current : 0,
        rowCount : 5,
        type : 0,
    },function(data) {
        var html = template("in_newsTemp", {list: data.data});
        $("#in_news").html(html);
    });
    $.get("api/news_list",{
        current : 0,
        rowCount : 5,
        type : 1,
    },function(data) {
        var html = template("in_newsTemp", {list: data.data});
        $("#in_dzone").html(html);
    });
    $.get("api/news_list",{
        current : 0,
        rowCount : 5,
        type : 2,
    },function(data) {
        var html = template("in_newsTemp", {list: data.data});
        $("#in_results").html(html);
    });
    $.get("api/news_list",{
        current : 0,
        rowCount : 5,
        type : 3,
    },function(data) {
        var html = template("in_newsTemp", {list: data.data});
        $("#in_emissions").html(html);
    });
</script>